package com.gln.bloger.action;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.apache.struts.action.ActionForm;
import org.apache.struts.action.ActionForward;
import org.apache.struts.action.ActionMapping;

public class IndexerAction extends BaseAction{

	/**
	 * show entry 
	 * @param mapping
	 * @param form
	 * @param request
	 * @param response
	 * @return
	 * @throws Exception
	 */
	public ActionForward index(ActionMapping mapping, ActionForm form,
		   HttpServletRequest request, HttpServletResponse response) 
	       throws Exception{
		long elapsedTime = getSearchService().index();
		request.setAttribute("elapsedTime", elapsedTime);
		return mapping.findForward("indexerView");
	}
}
